package com.moonstar;

import javax.swing.*;

public class myThread2 extends Thread{
    private JTextArea jt;

    myThread2(JTextArea jt){
        this.jt=jt;
    }

    @Override
    public void run() {
        while(true){
            try {
                sleep(10);
            } catch (InterruptedException e) {
                e.printStackTrace();
            }
            jt.setText(String.valueOf(work2.index2));
            work2.index2--;
        }
    }
}
